from modelscope import snapshot_download

model_dir = snapshot_download(
    model_id='Lightricks/LTX-Video-0.9.8-13B-distilled',
    local_dir="/home/fit/liuyebin/WORK/lingweidang/model_zoos/Lightricks/LTX-Video-0.9.8-13B-distilled",
    # allow_patterns=r"text_encoder/*",
    allow_patterns=r"transformer/*",
    revision="master"
)

# from modelscope.hub.file_download import model_file_download

# model_dir = model_file_download(model_id='CloseGPT/PixArt-XL-2-1024-MS', file_path='text_encoder/model-00001-of-00002.safetensors', local_dir="/home/fit/liuyebin/WORK/lingweidang/model_zoos/CloseGPT/PixArt-XL-2-1024-MS/text_encoder")
